using JoyfulHomeJourney.BackEnd.Infrastructure.EFCore;
using JoyfulHomeJourney.BackEnd.Infrastructure.Dtos.Responses.Objects;
using JoyfulHomeJourney.BackEnd.Infrastructure.Tools;
namespace JoyfulHomeJourney.BackEnd.Server.Instances.Extends.Responses
{
	public static class PointsLogsExtend
{
		public static ResponsePointsLogsDto ToResponseDto(this PointsLogs entity)
{			return new ResponsePointsLogsDto
			{
				createAt = entity.PlCreateAt,
				createAtStr =Tools.TimeToString(entity.PlCreateAt),
				id = entity.PlId,
				logDescription = entity.PlLogDescription,
				pointProductId = entity.PlPointProductId,
				pointsChangeCount = entity.PlPointsChangeCount,
				updateAt = entity.PlUpdateAt,
				updateAtStr =Tools.TimeToString(entity.PlUpdateAt),
				user = entity.PlUser,
			};
		}
	}
}
